<include file="__PUBLIC__/header"/>
<div class="page-container">
    <form class="form form-horizontal" id="form" method="post" action="{|U:'add'}">

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"><span class="c-red">*</span>标识名：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="text" class="input-text" value="Example" placeholder="请填写标识名" name="name" datatype="*"
                       nullmsg="请填写标识名"/>
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"></label>
            <div class="formControls col-xs-6 col-sm-6">
                只能是英文字母开头，且首字母大写，标识只能包含英文、数子、下划线
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"><span class="c-red">*</span>插件名：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="text" class="input-text" value="示例" placeholder="请填写插件名" name="title" datatype="*"
                       nullmsg="请填写插件名"/>
            </div>
            <div class="col-xs-3 col-sm-3">插件的中文名称</div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"><span class="c-red">*</span>版本号：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="text" class="input-text" value="1.0" placeholder="请填写版本号" name="version" datatype="*"
                       nullmsg="请填写版本号"/>
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"><span class="c-red">*</span>作者：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="text" class="input-text" value="无名" placeholder="请填写作者" name="author" datatype="*"
                       nullmsg="请填写作者"/>
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">描述：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <textarea class="textarea" placeholder="请填写描述信息" name="description" onkeyup="textarealength(this,100)">这是一个临时描述信息</textarea>
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">是否有后台：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="checkbox" name="has_adminlist" value="1"/> 有
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"></label>
            <div class="formControls col-xs-6 col-sm-6">
                访问方法:?g=Addon&m=插件名&c=Admin&a=index
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">开启外部访问：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="checkbox" name="has_outurl" value="1"/> 开启
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"></label>
            <div class="formControls col-xs-6 col-sm-6">
                访问方法:?g=Addon&m=插件名&c=Index&a=index
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">是否需要配置：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="checkbox" name="config" value="1" checked=""/> 需要
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">是否需要模板标签：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <input type="checkbox" name="has_outurl" value="1"/> 需要
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3">实现的钩子方法：</label>
            <div class="formControls col-xs-6 col-sm-6">
                <div class="select-box" style="width: 500px">
                    <select name="hooks[]" multiple="multiple" class="select" size="10">
                        <list from="$hooks" name="$h">
                            <option value="{$h.name}">{$h.name} ({$h.description})</option>
                        </list>
                    </select>
                </div>
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-3 col-sm-3"></label>
            <div class="formControls col-xs-6 col-sm-6">
                如果不挂钩子可以不选择
            </div>
            <div class="col-xs-3 col-sm-3"></div>
        </div>

        <div class="row cl">
            <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <button type="submit" class="btn btn-primary radius"><i class="iconfont icon-duigou1"></i> 提交</button>
                <button type="button" class="btn btn-default radius ml-20" onClick="layer_close();">&nbsp;&nbsp;取消&nbsp;&nbsp;</button>
            </div>
        </div>
    </form>
</div>
<include file="__PUBLIC__/footer"/>
<script>
    $(function () {
        $("#form").Validform({
            tiptype: 2,
            ajaxPost: true,
            showAllError: true,
            callback: function (ret) {
                ajax_progress(ret);

            }
        });
    })
</script>
</body>
</html>